﻿/*功能描述：系统设置-面试管理+出国考察游
作者：李周蓬
时间：2021-12-23
修改人：李周蓬
修改时间：2021-12-23*/
using HongStone.Domain.SystemSetupModel.InstitutionSettingModel;
using HongStone.Service;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace HongStone.API.Controllers
{
    [ApiExplorerSettings(GroupName = "SystemLZP")]
    [Route("api/[controller]/[action]")]
    [ApiController]
    public class SystemLZPController : ControllerBase
    {
        private readonly SystemLZPBll _systemLZPBll;
        public SystemLZPController(SystemLZPBll systemLZPBll)
        {
            _systemLZPBll = systemLZPBll;
        }
        /// <summary>
        /// 面试添加
        /// </summary>
        /// <param name="interview"></param>
        /// <returns></returns>
        [HttpPost]
        public IActionResult AddInterview(Interview interview)
        {
            return Ok(_systemLZPBll.AddInterview(interview));
        }
        /// <summary>
        /// 显示面试信息
        /// </summary>
        /// <param name="deptid"></param>
        /// <param name="name"></param>
        /// <param name="result"></param>
        /// <returns></returns>
        [HttpGet]
        public IActionResult ShowInterview(int deptid, string name, string result)
        {
            return Ok(_systemLZPBll.ShowInterview(deptid, name, result));
        }
        /// <summary>
        /// 显示出国旅游资格单
        /// </summary>
        /// <returns></returns>
        [HttpGet]
        public IActionResult ShowGo(string year)
        {
            return Ok(_systemLZPBll.ShowGo(year));
        }
        /// <summary>
        /// 显示出国旅游安排计算表
        /// </summary>
        /// <returns></returns>
        [HttpGet]
        public IActionResult ShowAn(string year)
        {
            return Ok(_systemLZPBll.ShowAn(year));
        }
        /// <summary>
        /// 显示出国旅游汇总表
        /// </summary>
        /// <returns></returns>
        [HttpGet]
        public IActionResult ShowHui(string year)
        {
            return Ok(_systemLZPBll.ShowHui(year));
        }
        /// <summary>
        /// 保存出国旅游安排计算表
        /// </summary>
        /// <returns></returns>
        [HttpPut]
        public IActionResult BaoCun(StaffGoList staffGoList)
        {
            return Ok(_systemLZPBll.BaoCun(staffGoList));
        }
    }
}
